﻿using e_commerce.BLL.Data;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace e_commerce.BLL.Services
{
    public interface IUserEnterpriseManager
    {
        #region 企业端接口
        /// <summary>
        /// 设置角色
        /// </summary>
        /// <param name="userId">用户id</param>
        /// <param name="roleId">角色id</param>
        void SetRolesToUser(int userId, int[] roleId);
        /// <summary>
        /// 
        /// </summary>
        /// <param name="userId"></param>
        /// <param name="permissionId"></param>
        void SetPermissionsToUser(int userId, int[] permissionId);
        /// <summary>
        /// 创建员工
        /// </summary>
        /// <param name="employeeName">员工名称</param>
        void CreateEmployee(string employeeName);
        /// <summary>
        /// 删除员工
        /// </summary>
        /// <param name="employeeId">员工id</param>
        void DeleteEmployeeByEmployeeId(int employeeId);
        /// <summary>
        /// 添加角色
        /// </summary>
        /// <param name="roleName">角色名</param>
        /// <param name="permissionids">权限id</param>
        void CreateRole(string roleName,int[] permissionids);
        /// <summary>
        /// 修改权限
        /// </summary>
        /// <param name="roleId">角色d</param>
        /// <param name="permisssionids">权限数组</param>
        /// <param name="roleName">权限名</param>
        void ModifyRoleByRoleId(int roleId,int[] permisssionids,string roleName);
        /// <summary>
        /// 删除角色及相应权限
        /// </summary>
        /// <param name="roleId">角色ID</param>
        void DeleteRoleByRoleId(int roleId);


        #endregion
    }
}
